package com.qxp.simplerpc.entity;

/**
 * AjaxJson controller to response the request
 */
public class AjaxJson {

    private boolean success;

    private Object result;

    private Throwable e;

    private String message;

    public AjaxJson setSuccess(boolean s){
        this.success = s;
        return this;
    }

    public boolean isSuccess() {
        return success;
    }

    public Object getResult() {
        return result;
    }

    public AjaxJson setResult(Object result) {
        this.result = result;
        return this;
    }

    public Throwable getE() {
        return e;
    }

    public AjaxJson setE(Throwable e) {
        this.e = e;
        return this;
    }

    public String getMessage() {
        return message;
    }

    public AjaxJson setMessage(String message) {
        this.message = message;
        return this;
    }

    @Override
    public String toString() {
        return "AjaxJson{" +
                "success=" + success +
                ", result=" + result +
                ", e=" + e +
                ", message='" + message + '\'' +
                '}';
    }


}
